package com.catmiao.spark.util

import java.io.InputStreamReader
import java.util.Properties

/**
 * @title: PropertiesUtil
 * @projectName spark_study
 * @description: TODO
 * @author ChengMiao
 * @date 2024/3/26 22:53
 */
object PropertiesUtil {
  def load(propertiesName: String): Properties = {
    val prop = new Properties()
    prop.load(new
        InputStreamReader(Thread.currentThread().getContextClassLoader.getResourceAsStream(propertiesName), "UTF-8"))
    prop
  }
}